package org.ihelpuoo.orm.filter;

import org.ihelpuoo.orm.IIIException;
import org.ihelpuoo.orm.ObjectRule;

public class ObjectFilter implements Filter
{

	private ObjectRule	rule;
	private Object		obj;
	private FieldFilter	actived;
	private FieldFilter	locked;

	public ObjectFilter(ObjectRule rule, Object obj, FieldFilter actived, FieldFilter locked)
	{
		this.rule = rule;
		this.obj = obj;
		this.actived = actived;
		this.locked = locked;
	}

	public String getString() throws IIIException
	{
		return rule.makeSQLCondition(obj,actived,locked).toString();
	}
}
